package STUDENT.TRANBANGTUNG.day05_20_2016.bai1;

import java.util.Scanner;

public class View {
	public static void main(String[] args) {
		Scanner sc;
		double b = 0;
		double sum = 0;
		System.out.println("nhap vao gia tri phan tu trong mang!");
		sc = new Scanner(System.in);
		Object obj = new Object(sc.nextInt());
		double[] array = obj.getArray();
		for (int i = 0; i < array.length; i++) {
			System.out.println("nhap phan tu thu " + i);
			sc = new Scanner(System.in);
			b = sc.nextDouble();
			array[i] = b;
		}
		obj.setArray(array);
		Controller con = new Controller();
		sum = con.tinhtong(obj);
		System.out.println("tong la: " + sum);
		double max = con.timmax(obj);
		System.out.println("max la: " + max);
		double min = con.timmin(obj);
		System.out.println("min la: " + min);
		String ds = con.danhsachmax(obj);
		System.out.println("so luong so lon nhat la: " + ds);
	}
}
